<%@page import="com.db.workcall.WorkCallVO"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
  <center>
    <table border=0 width=700>
      <tr>
        <td align=left>
	      <s:if test="kind==2">
	        <br><b><font size=3>보낸 업무연락</font></b><br>
	      </s:if>
	      <s:if test="kind==3">
	        <br><b><font size=3>받은 업무연락</font></b><br>
	      </s:if>
	      <s:if test="kind==4">
	       <br><b><font size=3>휴지통</font></b><br>
	      </s:if>
        </td>
      </tr>
      <tr>
        <td align="right">${curpage } page / ${totalpage } pages</td>
      </tr>
    </table>
    <table border=0 width=700 cellspacing="0">
      <tr><td colspan="4" height=1 bgcolor="rgb(91,140,217)"></td></tr>
      <tr height="30">
       <th width=10%>번호</th>
       <th width=40%>제목</th>
       <s:if test="kind==2">
         <th width=15%>받는이</th>
       </s:if>
       <s:elseif test="kind==3||kind==4">
         <th width=15%>보낸이</th>
       </s:elseif>
       <th width=25%>작성일</th>
      </tr>
      <tr><td colspan="4" height=1 bgcolor="rgb(91,140,217)"></td></tr>
      <s:iterator value="list">
        <tr onmouseover="this.style.backgroundColor='#eaf0fa'" onmouseout="this.style.backgroundColor=''" height="30">
         <td width=10%>${no }</td>
         <td width=40% align=left>
          <s:if test="kind==2">          	
            <s:a href="/ssteam/workcall/content.do?no=%{no }&kind=2" theme="ajax" targets="result">${subject }</s:a>
          </s:if>
          <s:elseif test="kind==3">          
            <s:a href="/ssteam/workcall/content.do?no=%{no }&kind=3" theme="ajax" targets="result">${subject }</s:a>
          </s:elseif>
          <s:else>          
		    <s:a href="/ssteam/workcall/content.do?no=%{no }&kind=4" theme="ajax" targets="result">${subject }</s:a>          
          </s:else>
         </td>
        <s:if test="kind==2">
          <td width=15%>${name }</td>
        </s:if>
        <s:if test="kind==3||kind==4">
          <td width=15%>${name }</td>
        </s:if>
         <td width=25%><s:date name="writeday" format="yyyy-MM-dd"/></td>
        </tr>
        <tr>
          <td colspan=4 height=0 bgcolor="#dadada"></td>
        </tr>
      </s:iterator>
    </table>
    <table border=0	width="700">
      <tr>
       <td align="left">&nbsp;</td>
       <td align="right">
       <s:if test="kind==2">
         <s:a href="/ssteam/workcall/list.do?page=%{curpage>1?curpage-1:curpage }&kind=2&sabun=%{#session.user.sabun }" theme="ajax" targets="result">이전</s:a>&nbsp;&nbsp;
         <s:a href="/ssteam/workcall/list.do?page=%{curpage<totalpage?curpage+1:curpage }&kind=2&sabun=%{#session.user.sabun }" theme="ajax" targets="result">다음</s:a>
       </s:if>
       <s:elseif test="kind==3">
         <s:a href="/ssteam/workcall/list.do?page=%{curpage>1?curpage-1:curpage }&kind=3&sabun=%{#session.user.sabun }" theme="ajax" targets="result">이전</s:a>&nbsp;&nbsp;
         <s:a href="/ssteam/workcall/list.do?page=%{curpage<totalpage?curpage+1:curpage }&kind=3&sabun=%{#session.user.sabun }" theme="ajax" targets="result">다음</s:a>
       </s:elseif>
       <s:else>
         <s:a href="/ssteam/workcall/list.do?page=%{curpage>1?curpage-1:curpage }&kind=4" theme="ajax" targets="result">이전</s:a>&nbsp;&nbsp;
         <s:a href="/ssteam/workcall/list.do?page=%{curpage<totalpage?curpage+1:curpage }&kind=4" theme="ajax" targets="result">다음</s:a>
       </s:else>  
       </td>
      </tr>
    </table>
  </center>
</body>
</html>
